package com.qf.feign;/*
 *保护你的大熊
 *2021/12/20
 *20:51
 */

import com.qf.fallback.GoodsFallback;
import com.qf.fallback.GoodsFallbackFactory;
import com.qf.pojo.Goods;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

@FeignClient(value = "QF-GOODS")
public interface GoodsFeign {

    @RequestMapping("/index")
    public String index();


    @GetMapping("/findById/{id}")
    public Goods findById(@PathVariable Integer id);

    @GetMapping("/findById")
    public Goods findById2(@RequestParam("id") Integer id);

    @PostMapping("/save")
    public String save(Goods goods);

}
